package com.zuihai.app.mvp.model.entity;

import android.os.Parcel;
import android.os.Parcelable;

import com.google.gson.annotations.Expose;
import com.google.gson.annotations.SerializedName;

import java.util.List;

/**
 * Created by Administrator on 2017/6/21 0021.
 */

public class SearchItem {
    @SerializedName("toutiao_id")
    @Expose
    public String id;
    @SerializedName("picture")
    @Expose
    public List<Picture> pictures;
    @SerializedName("title")
    @Expose
    public String title;
    @SerializedName("name")
    @Expose
    public String name;
    @SerializedName("content")
    @Expose
    public String content;
    @SerializedName("muban_Tag")
    @Expose
    public int muban_Tag;
    @SerializedName("laiyuan")
    @Expose
    public String source;
    @SerializedName("pinglun_count")
    @Expose
    public int careCount;

    public static class Picture implements Parcelable {
        @SerializedName("picture_url")
        @Expose
        public String pictureUrl;

        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeString(this.pictureUrl);
        }

        public Picture() {
        }

        protected Picture(Parcel in) {
            this.pictureUrl = in.readString();
        }

        public static final Creator<Picture> CREATOR = new Creator<Picture>() {
            @Override
            public Picture createFromParcel(Parcel source) {
                return new Picture(source);
            }

            @Override
            public Picture[] newArray(int size) {
                return new Picture[size];
            }
        };
    }
}
